import Vue from 'vue'
import VueRouter from 'vue-router'

Vue.use(VueRouter)

const routes = [
  {
    path: '/',
    redirect:"/login"
    // component: Home
  },
  {
    path: '/login',
    name: 'login',
    // component: Home
    component: () => import('../views/Login.vue'),
  },
  {
    path: '/register',
    name: 'register',
    // component: Home
    component: () => import('../views/Register.vue'),
  },
  {
    path: '/about',
    name: 'about',
    component: () => import('../views/About.vue')
  }
]

const router = new VueRouter({
  // mode: 'history',
  base: process.env.BASE_URL,
  routes
})

export default router
